<template>
  <div id="results-movies">
    <div
      v-for="(item, index) in mvs"
      :key="index"
      class="mv-item">
      <div class="img-container">
        <img :src="item.cover" alt="">
        <div class="play-count">
          <i class="el-icon-video-camera"></i>
          111
        </div>
      </div>
      <div class="content">
        <div class="mv-name">
          <div class="tag">
            MV
          </div>
          {{ item.name }}
        </div>
        <div class="artist">{{ item.artistName }}</div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: 'ResultsMovies',
  props: {
    mvs: {
      type: Array,
      default () {
        return []
      }
    }
  }
}
</script>

<style scoped lang="less">
#results-movies {
  user-select: none;
  .mv-item {
    width: 25%;
    padding: 25px 25px 50px 25px;
    float: left;
    .img-container {
      cursor: pointer;
      position: relative;
      padding-top: 56%;
      height: 0;
      width: 100%;
      img {
        width: 100%;
        position: absolute;
        top: 0;
      }
      .play-count {
        float: right;
        background-image: linear-gradient(to right, white , black);
        color: #f1f0f2;
        font-size: 13px;
        position: absolute;
        right: 0;
        top: 0;
      }
    }
    .content {
      position: relative;
      > div {
        cursor: pointer;
        position: absolute;
        width: 100%;
        font-size: 13px;
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
      }
      .mv-name {
        bottom: -24px;
        .tag {
          display: inline-block;
          margin-right: 5px;
          left: 0;
          color: #e13f40;
          border: 1px solid #e87778;
        }
      }
      .artist {
        color: #a599a5;
        bottom: -48px;
      }
    }
  }
}
</style>
